home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 7 / Amiga Format AFCD07 (Dec 1996, Issue 91).iso / serious / shareware / programming / emacs-complete / fsf / emacs / info / emacs-13 < prev    next >
Encoding:
GNU Info File  |  1994-10-06  |  48.8 KB  |  1,162 lines

  1. This is Info file ../info/emacs, produced by Makeinfo-1.54 from the
  2. input file emacs.texi.
  3.  
  4. 
  5. File: emacs,  Node: Mail Mode,  Next: Distracting NSA,  Prev: Mail Aliases,  Up: Sending Mail
  6.  
  7. Mail Mode
  8. =========
  9.  
  10.    The major mode used in the `*mail*' buffer is Mail mode, which is
  11. much like Text mode except that various special commands are provided on
  12. the `C-c' prefix.  These commands all have to do specifically with
  13. editing or sending the message.
  14.  
  15. `C-c C-s'
  16.      Send the message, and leave the `*mail*' buffer selected
  17.      (`mail-send').
  18.  
  19. `C-c C-c'
  20.      Send the message, and select some other buffer
  21.      (`mail-send-and-exit').
  22.  
  23. `C-c C-f C-t'
  24.      Move to the `To' header field, creating one if there is none
  25.      (`mail-to').
  26.  
  27. `C-c C-f C-s'
  28.      Move to the `Subject' header field, creating one if there is none
  29.      (`mail-subject').
  30.  
  31. `C-c C-f C-c'
  32.      Move to the `CC' header field, creating one if there is none
  33.      (`mail-cc').
  34.  
  35. `C-c C-w'
  36.      Insert the file `~/.signature' at the end of the message text
  37.      (`mail-signature').
  38.  
  39. `C-c C-y'
  40.      Yank the selected message from Rmail (`mail-yank-original').  This
  41.      command does nothing unless your command to start sending a
  42.      message was issued with Rmail.
  43.  
  44. `C-c C-q'
  45.      Fill all paragraphs of yanked old messages, each individually
  46.      (`mail-fill-yanked-message').
  47.  
  48. `M-x ispell-message'
  49.      Do spelling correction on the message text, but not on citations
  50.      from other messages.
  51.  
  52.    There are two ways to send the message.  `C-c C-s' (`mail-send')
  53. sends the message and marks the `*mail*' buffer unmodified, but leaves
  54. that buffer selected so that you can modify the message (perhaps with
  55. new recipients) and send it again.  `C-c C-c' (`mail-send-and-exit')
  56. sends and then deletes the window or switches to another buffer.  It
  57. puts the `*mail*' buffer at the lowest priority for reselection by
  58. default, since you are finished with using it.  This is the usual way
  59. to send the message.
  60.  
  61.    Mail mode provides special commands for editing the headers and text
  62. of the message before you send it.  There are three commands defined to
  63. move point to particular header fields, all based on the prefix `C-c
  64. C-f' (`C-f' is for "field").  They are `C-c C-f C-t' (`mail-to') to
  65. move to the `To' field, `C-c C-f C-s' (`mail-subject') for the
  66. `Subject' field, and `C-c C-f C-c' (`mail-cc') for the `CC' field.  If
  67. the field in question does not exist, these commands create one.  We
  68. provide special motion commands for these particular fields because
  69. they are the fields users most often want to edit.
  70.  
  71.    `C-c C-w' (`mail-signature') adds a standard piece text at the end
  72. of the message to say more about who you are.  The text comes from the
  73. file `.signature' in your home directory.  To insert signatures
  74. automatically, set the variable `mail-signature' non-`nil'; then
  75. starting a mail message automatically inserts the contents of your
  76. `.signature' file.  If you want to omit your signature from a
  77. particular message, delete it from the buffer before you send the
  78. message.
  79.  
  80.    When mail sending is invoked from the Rmail mail reader using an
  81. Rmail command, `C-c C-y' can be used inside the `*mail*' buffer to
  82. insert the text of the message you are replying to.  Normally it
  83. indents each line of that message four spaces and eliminates most
  84. header fields.  A numeric argument specifies the number of spaces to
  85. indent.  An argument of just `C-u' says not to indent at all and not to
  86. eliminate anything.  `C-c C-y' always uses the current message from the
  87. Rmail buffer, so you can insert several old messages by selecting one
  88. in Rmail, switching to `*mail*' and yanking it, then switching back to
  89. Rmail to select another.
  90.  
  91.    You can specify the text for `C-c C-y' to insert at the beginning of
  92. each line: set `mail-yank-prefix' to the desired string.  (A value of
  93. `nil' means to use indentation; this is the default.) However, `C-u C-c
  94. C-y' never adds anything at the beginning of the inserted lines,
  95. regardless of the value of `mail-yank-prefix'.
  96.  
  97.    After using `C-c C-y', you can use the command `C-c C-q'
  98. (`mail-fill-yanked-message') to fill the paragraphs of the yanked old
  99. message or messages.  One use of `C-c C-q' fills all such paragraphs,
  100. each one individually.  *Note Filling::.
  101.  
  102.    You can do spelling correction on the message text you have written
  103. with the command `M-x ispell-message'.  If you have yanked an incoming
  104. message into the outgoing draft, this command skips what was yanked,
  105. but it checks the text that you yourself inserted.  (It looks for
  106. indentation or `mail-yank-prefix' to distinguish the cited lines from
  107. your input.)  *Note Spelling::.
  108.  
  109.    Mail mode defines the character `%' as a word separator; this is
  110. helpful for using the word commands to edit mail addresses.
  111.  
  112.    Mail mode is normally used in buffers set up automatically by the
  113. `mail' command and related commands.  However, you can also switch to
  114. Mail mode in a file-visiting buffer.  That is a useful thing to do if
  115. you have saved draft message text in a file.  In a file-visiting buffer,
  116. `C-c C-c' does not clear the modified flag, because only saving the
  117. file should do that.  As a result, you don't get a warning about trying
  118. to send the same message twice.
  119.  
  120.    Turning on Mail mode (which `C-x m' does automatically) runs the
  121. normal hooks `text-mode-hook' and `mail-mode-hook'.  Initializing a new
  122. outgoing message runs the normal hook `mail-setup-hook'; if you want to
  123. add special fields to your mail header or make other changes to the
  124. appearance of the mail buffer, use that hook.  *Note Hooks::.
  125.  
  126.    The main difference between these hooks is just when they are
  127. invoked.  Whenever you type `M-x mail', `mail-mode-hook' runs as soon
  128. as the `*mail*' buffer is created.  Then the `mail-setup' function puts
  129. in the default contents of the buffer.  After these default contents
  130. are inserted, `mail-setup-hook' runs.
  131.  
  132. 
  133. File: emacs,  Node: Distracting NSA,  Prev: Mail Mode,  Up: Sending Mail
  134.  
  135. Distracting the NSA
  136. ===================
  137.  
  138.    `M-x spook' adds a line of randomly chosen keywords to an outgoing
  139. mail message.  The keywords are chosen from a list of words that suggest
  140. you are discussing something subversive.
  141.  
  142.    The idea behind this feature is that the suspicion that the NSA
  143. snoops on all electronic mail messages that contain keywords suggesting
  144. they might be interested.  (The NSA says they don't, but we can't take
  145. their word for it.)  The idea is that if lots of people add suspicious
  146. words to their messages, the NSA will get so busy with spurious input
  147. that they will have to give up reading it all.
  148.  
  149.    Here's how to insert spook keywords automatically whenever you start
  150. entering an outgoing message:
  151.  
  152.      (add-hook 'mail-setup-hook 'spook)
  153.  
  154.    Whether or not this confuses the NSA, it at least amuses people.
  155.  
  156. 
  157. File: emacs,  Node: Rmail,  Next: Dired,  Prev: Sending Mail,  Up: Top
  158.  
  159. Reading Mail with Rmail
  160. ***********************
  161.  
  162.    Rmail is an Emacs subsystem for reading and disposing of mail that
  163. you receive.  Rmail stores mail messages in files called Rmail files.
  164. Reading the message in an Rmail file is done in a special major mode,
  165. Rmail mode, which redefines most letters to run commands for managing
  166. mail.
  167.  
  168. * Menu:
  169.  
  170. * Basic: Rmail Basics.       Basic concepts of Rmail, and simple use.
  171. * Scroll: Rmail Scrolling.   Scrolling through a message.
  172. * Motion: Rmail Motion.      Moving to another message.
  173. * Deletion: Rmail Deletion.  Deleting and expunging messages.
  174. * Inbox: Rmail Inbox.        How mail gets into the Rmail file.
  175. * Files: Rmail Files.        Using multiple Rmail files.
  176. * Output: Rmail Output.         Copying message out to files.
  177. * Labels: Rmail Labels.      Classifying messages by labeling them.
  178. * Reply: Rmail Reply.        Sending replies to messages you are viewing.
  179. * Summary: Rmail Summary.    Summaries show brief info on many messages.
  180. * Sort: Rmail Sorting.       Sorting messages in Rmail.
  181. * Display: Rmail Display.    How Rmail displays a message; customization.
  182. * Editing: Rmail Editing.    Editing message text and headers in Rmail.
  183. * Digest: Rmail Digest.      Extracting the messages from a digest message.
  184. * Out of Rmail::         Converting an Rmail file to mailbox format.
  185. * Rot13: Rmail Rot13.         Reading messages encoded in the rot13 code.
  186.  
  187. 
  188. File: emacs,  Node: Rmail Basics,  Next: Rmail Scrolling,  Up: Rmail
  189.  
  190. Basic Concepts of Rmail
  191. =======================
  192.  
  193.    Using Rmail in the simplest fashion, you have one Rmail file
  194. `~/RMAIL' in which all of your mail is saved.  It is called your
  195. "primary Rmail file".  The command `M-x rmail' reads your primary Rmail
  196. file, merges new mail in from your inboxes, displays the first message
  197. you haven't read yet, and lets you begin reading.
  198.  
  199.    Rmail uses narrowing to hide all but one message in the Rmail file.
  200. The message that is shown is called the "current message".  Rmail
  201. mode's special commands can do such things as delete the current
  202. message, copy it into another file, send a reply, or move to another
  203. message.  You can also create multiple Rmail files and use Rmail to move
  204. messages between them.
  205.  
  206.    Within the Rmail file, messages are normally arranged sequentially in
  207. order of receipt; you can specify other ways to sort them.  Messages are
  208. assigned consecutive integers as their "message numbers".  The number
  209. of the current message is displayed in Rmail's mode line, followed by
  210. the total number of messages in the file.  You can move to a message by
  211. specifying its message number with the `j' key (*note Rmail Motion::.).
  212.  
  213.    Following the usual conventions of Emacs, changes in an Rmail file
  214. become permanent only when the file is saved.  You can save it with `s'
  215. (`rmail-save'), which also expunges deleted messages from the file
  216. first (*note Rmail Deletion::.).  To save the file without expunging,
  217. use `C-x C-s'.  Rmail also saves the Rmail file after merging new mail
  218. from an inbox file (*note Rmail Inbox::.).
  219.  
  220.    You can exit Rmail with `q' (`rmail-quit'); this expunges and saves
  221. the Rmail file and then switches to another buffer.  But there is no
  222. need to `exit' formally.  If you switch from Rmail to editing in other
  223. buffers, and never happen to switch back, you have exited.  (The Rmail
  224. command `b', `rmail-bury', does this for you.)  Just make sure to save
  225. the Rmail file eventually (like any other file you have changed).  `C-x
  226. s' is a good enough way to do this (*note Saving::.).
  227.  
  228. 
  229. File: emacs,  Node: Rmail Scrolling,  Next: Rmail Motion,  Prev: Rmail Basics,  Up: Rmail
  230.  
  231. Scrolling Within a Message
  232. ==========================
  233.  
  234.    When Rmail displays a message that does not fit on the screen, you
  235. must scroll through it to read the rest.  You could do this with `C-v',
  236. `M-v' and `M-<', but in Rmail scrolling is so frequent that it deserves
  237. to be easier to type.
  238.  
  239. `SPC'
  240.      Scroll forward (`scroll-up').
  241.  
  242. `DEL'
  243.      Scroll backward (`scroll-down').
  244.  
  245. `.'
  246.      Scroll to start of message (`rmail-beginning-of-message').
  247.  
  248.    Since the most common thing to do while reading a message is to
  249. scroll through it by screenfuls, Rmail makes SPC and DEL synonyms of
  250. `C-v' (`scroll-up') and `M-v' (`scroll-down')
  251.  
  252.    The command `.' (`rmail-beginning-of-message') scrolls back to the
  253. beginning of the selected message.  This is not quite the same as `M-<':
  254. for one thing, it does not set the mark; for another, it resets the
  255. buffer boundaries to the current message if you have changed them.
  256.  
  257. 
  258. File: emacs,  Node: Rmail Motion,  Next: Rmail Deletion,  Prev: Rmail Scrolling,  Up: Rmail
  259.  
  260. Moving Among Messages
  261. =====================
  262.  
  263.    The most basic thing to do with a message is to read it.  The way to
  264. do this in Rmail is to make the message current.  The usual practice is
  265. to move sequentially through the file, since this is the order of
  266. receipt of messages.  When you enter Rmail, you are positioned at the
  267. first message that you have not yet made current (that is, the first one
  268. that has the `unseen' attribute; *note Rmail Labels::.).  Move forward
  269. to see the other new messages; move backward to reexamine old messages.
  270.  
  271. `n'
  272.      Move to the next nondeleted message, skipping any intervening
  273.      deleted messages (`rmail-next-undeleted-message').
  274.  
  275. `p'
  276.      Move to the previous nondeleted message
  277.      (`rmail-previous-undeleted-message').
  278.  
  279. `M-n'
  280.      Move to the next message, including deleted messages
  281.      (`rmail-next-message').
  282.  
  283. `M-p'
  284.      Move to the previous message, including deleted messages
  285.      (`rmail-previous-message').
  286.  
  287. `j'
  288.      Move to the first message.  With argument N, move to message
  289.      number N (`rmail-show-message').
  290.  
  291. `>'
  292.      Move to the last message (`rmail-last-message').
  293.  
  294. `<'
  295.      Move to the first message (`rmail-first-message').
  296.  
  297. `M-s REGEXP RET'
  298.      Move to the next message containing a match for REGEXP
  299.      (`rmail-search').
  300.  
  301. `- M-s REGEXP RET'
  302.      Move to the previous message containing a match for REGEXP.
  303.  
  304.    `n' and `p' are the usual way of moving among messages in Rmail.
  305. They move through the messages sequentially, but skip over deleted
  306. messages, which is usually what you want to do.  Their command
  307. definitions are named `rmail-next-undeleted-message' and
  308. `rmail-previous-undeleted-message'.  If you do not want to skip deleted
  309. messages--for example, if you want to move to a message to undelete
  310. it--use the variants `M-n' and `M-p' (`rmail-next-message' and
  311. `rmail-previous-message').  A numeric argument to any of these commands
  312. serves as a repeat count.
  313.  
  314.    In Rmail, you can specify a numeric argument by typing just the
  315. digits.  You don't need to type `C-u' first.
  316.  
  317.    The `M-s' (`rmail-search') command is Rmail's version of search.
  318. The usual incremental search command `C-s' works in Rmail, but it
  319. searches only within the current message.  The purpose of `M-s' is to
  320. search for another message.  It reads a regular expression (*note
  321. Regexps::.) nonincrementally, then searches starting at the beginning
  322. of the following message for a match.  It then selects that message.
  323. If REGEXP is empty, `M-s' reuses the regexp used the previous time.
  324.  
  325.    To search backward in the file for another message, give `M-s' a
  326. negative argument.  In Rmail you can do this with `- M-s'.
  327.  
  328.    It is also possible to search for a message based on labels.  *Note
  329. Rmail Labels::.
  330.  
  331.    To move to a message specified by absolute message number, use `j'
  332. (`rmail-show-message') with the message number as argument.  With no
  333. argument, `j' selects the first message.  `<' (`rmail-first-message')
  334. also selects the first message.  `>' (`rmail-last-message') selects the
  335. last message.
  336.  
  337. 
  338. File: emacs,  Node: Rmail Deletion,  Next: Rmail Inbox,  Prev: Rmail Motion,  Up: Rmail
  339.  
  340. Deleting Messages
  341. =================
  342.  
  343.    When you no longer need to keep a message, you can "delete" it.  This
  344. flags it as ignorable, and some Rmail commands pretend it is no longer
  345. present; but it still has its place in the Rmail file, and still has its
  346. message number.
  347.  
  348.    "Expunging" the Rmail file actually removes the deleted messages.
  349. The remaining messages are renumbered consecutively.  Expunging is the
  350. only action that changes the message number of any message, except for
  351. undigestifying (*note Rmail Digest::.).
  352.  
  353. `d'
  354.      Delete the current message, and move to the next nondeleted message
  355.      (`rmail-delete-forward').
  356.  
  357. `C-d'
  358.      Delete the current message, and move to the previous nondeleted
  359.      message (`rmail-delete-backward').
  360.  
  361. `u'
  362.      Undelete the current message, or move back to a deleted message and
  363.      undelete it (`rmail-undelete-previous-message').
  364.  
  365. `x'
  366.      Expunge the Rmail file (`rmail-expunge').
  367.  
  368.    There are two Rmail commands for deleting messages.  Both delete the
  369. current message and select another message.  `d'
  370. (`rmail-delete-forward') moves to the following message, skipping
  371. messages already deleted, while `C-d' (`rmail-delete-backward') moves
  372. to the previous nondeleted message.  If there is no nondeleted message
  373. to move to in the specified direction, the message that was just
  374. deleted remains current.
  375.  
  376.    To make all the deleted messages finally vanish from the Rmail file,
  377. type `x' (`rmail-expunge').  Until you do this, you can still
  378. "undelete" the deleted messages.  The undeletion command, `u'
  379. (`rmail-undelete-previous-message'), is designed to cancel the effect
  380. of a `d' command in most cases.  It undeletes the current message if
  381. the current message is deleted.  Otherwise it moves backward to
  382. previous messages until a deleted message is found, and undeletes that
  383. message.
  384.  
  385.    You can usually undo a `d' with a `u' because the `u' moves back to
  386. and undeletes the message that the `d' deleted.  But this does not work
  387. when the `d' skips a few already-deleted messages that follow the
  388. message being deleted; then the `u' command undeletes the last of the
  389. messages that were skipped.  There is no clean way to avoid this
  390. problem.  However, by repeating the `u' command, you can eventually get
  391. back to the message that you intend to undelete.  You can also select a
  392. particular deleted message with the `M-p' command, then type `u' to
  393. undelete it.
  394.  
  395.    A deleted message has the `deleted' attribute, and as a result
  396. `deleted' appears in the mode line when the current message is deleted.
  397. In fact, deleting or undeleting a message is nothing more than adding
  398. or removing this attribute.  *Note Rmail Labels::.
  399.  
  400. 
  401. File: emacs,  Node: Rmail Inbox,  Next: Rmail Files,  Prev: Rmail Deletion,  Up: Rmail
  402.  
  403. Rmail Files and Inboxes
  404. =======================
  405.  
  406.    The operating system places incoming mail for you in a file that we
  407. call your "inbox".  When you start up Rmail, it copies the new messages
  408. from your inbox into your primary Rmail file, an Rmail file, which also
  409. contains other messages saved from previous Rmail sessions.  It is in
  410. this file that you actually read the mail with Rmail.  This operation
  411. is called "getting new mail".  You can get new mail at any time in
  412. Rmail by typing `g'.  The inbox file name is usually
  413. `/var/mail/USERNAME', `/usr/spool/mail/USERNAME', or
  414. `/usr/mail/USERNAME', depending on your operating system.
  415.  
  416.    There are three reason for having separate Rmail files and inboxes.
  417.  
  418.   1. The inbox file format varies between operating systems and
  419.      according to the other mail software in use.  Only one part of
  420.      Rmail needs to know about the alternatives, and it need only
  421.      understand how to convert all of them to Rmail's own format.
  422.  
  423.   2. The inbox file format usually doesn't provide a place for all the
  424.      information that Rmail records.
  425.  
  426.   3. It is very cumbersome to access an inbox file without danger of
  427.      losing mail, because it is necessary to interlock with mail
  428.      delivery.  Moreover, different operating systems use different
  429.      interlocking techniques.  The strategy of moving mail out of the
  430.      inbox once and for all into a separate Rmail file avoids the need
  431.      for interlocking in all the rest of Rmail, since only Rmail
  432.      operates on the Rmail file.
  433.  
  434.    When getting new mail, Rmail first copies the new mail from the inbox
  435. file to the Rmail file; then it saves the Rmail file; then it truncates
  436. the inbox file.  This way, a system crash may cause duplication of mail
  437. between the inbox and the Rmail file, but cannot lose mail.
  438.  
  439.    Copying mail from an inbox in the system's mailer directory actually
  440. puts it in an intermediate file `~/.newmail-INBOXNAME'.  The C program
  441. that does interlocking with the mailer is designed to write its output
  442. into a file.  Once this program finishes, Rmail reads that file, merges
  443. the new mail, saves the Rmail file, and only then deletes the
  444. intermediate file.  If there is a crash at the wrong time, this file
  445. continues to exist and Rmail will use it again the next time it gets new
  446. mail from that inbox.
  447.  
  448. 
  449. File: emacs,  Node: Rmail Files,  Next: Rmail Output,  Prev: Rmail Inbox,  Up: Rmail
  450.  
  451. Multiple Rmail Files
  452. ====================
  453.  
  454.    Rmail operates by default on your "primary Rmail file", which is
  455. named `~/RMAIL' and receives your incoming mail from your system inbox
  456. file.  But you can also have other Rmail files and edit them with
  457. Rmail.  These files can receive mail through their own inboxes, or you
  458. can move messages into them with explicit Rmail commands (*note Rmail
  459. Output::.).
  460.  
  461. `i FILE RET'
  462.      Read FILE into Emacs and run Rmail on it (`rmail-input').
  463.  
  464. `M-x set-rmail-inbox-list RET FILES RET'
  465.      Specify inbox file names for current Rmail file to get mail from.
  466.  
  467. `g'
  468.      Merge new mail from current Rmail file's inboxes
  469.      (`rmail-get-new-mail').
  470.  
  471. `C-u g FILE RET'
  472.      Merge new mail from inbox file FILE.
  473.  
  474.    To run Rmail on a file other than your primary Rmail file, you may
  475. use the `i' (`rmail-input') command in Rmail.  This visits the file in
  476. Rmail mode.  You can use `M-x rmail-input' even when not in Rmail.
  477.  
  478.    The file you read with `i' should normally be a valid Rmail file.
  479. If it is not, Rmail tries to decompose it into a stream of messages in
  480. various known formats.  If it succeeds, it converts the whole file to an
  481. Rmail file.  If you specify a file name that doesn't exist, `i'
  482. initializes a new buffer for creating a new Rmail file.
  483.  
  484.    You can also select an Rmail file from a menu.  Choose first the menu
  485. bar Classify item, then from the Classify menu choose the Input Rmail
  486. File item; then choose the Rmail file you want.  The variables
  487. `rmail-secondary-file-directory' and `rmail-secondary-file-regexp'
  488. specify which files to offer in the menu: the first variable says which
  489. directory to find them in; the second says which files in that
  490. directory to offer (all those that match the regular expression).
  491. These variables also apply to choosing a file for output (*note Rmail
  492. Output::.).
  493.  
  494.    Each Rmail file can contain a list of inbox file names; you can
  495. specify this list with `M-x set-rmail-inbox-list RET FILES RET'.  The
  496. argument can contain any number of file names, separated by commas.  It
  497. can also be empty, which specifies that this file should have no
  498. inboxes.  Once a list of inboxes is specified, the Rmail file remembers
  499. it permanently until you specify a different list.
  500.  
  501.    As a special exception, if your primary Rmail file does not specify
  502. any inbox files, it uses your standard system inbox.
  503.  
  504.    The `g' command (`rmail-get-new-mail') merges mail into the current
  505. Rmail file from its specified inboxes.  If the Rmail file has no
  506. inboxes, `g' does nothing.  The command `M-x rmail' also merges new
  507. mail into your primary Rmail file.
  508.  
  509.    To merge mail from a file that is not the usual inbox, give the `g'
  510. key a numeric argument, as in `C-u g'.  Then it reads a file name and
  511. merges mail from that file.  The inbox file is not deleted or changed
  512. in any way when `g' with an argument is used.  This is, therefore, a
  513. general way of merging one file of messages into another.
  514.  
  515. 
  516. File: emacs,  Node: Rmail Output,  Next: Rmail Labels,  Prev: Rmail Files,  Up: Rmail
  517.  
  518. Copying Messages Out to Files
  519. =============================
  520.  
  521.    These commands copy messages from an Rmail file into another file.
  522.  
  523. `o FILE RET'
  524.      Append a copy of the current message to the file FILE, using Rmail
  525.      file format by default (`rmail-output-to-rmail-file').
  526.  
  527. `C-o FILE RET'
  528.      Append a copy of the current message to the file FILE, using
  529.      system inbox file format by default (`rmail-output').
  530.  
  531.    The commands `o' and `C-o' copy the current message into a specified
  532. file.  This file may be an Rmail file or it may be in system inbox
  533. format; the output commands ascertain the file's format and write the
  534. copied message in that format.
  535.  
  536.    The `o' and `C-o' commands differ in two ways: each has its own
  537. separate default file name, and each specifies a choice of format to
  538. use when the file does not already exist.  The `o' command uses Rmail
  539. format when it creates a new file, while `C-o' uses system inbox format
  540. for a new file.  The default file name for `o' is the file name used
  541. last with `o', and the default file name for `C-o' is the file name
  542. used last with `C-o'.
  543.  
  544.    If the output file is an Rmail file currently visited in an Emacs
  545. buffer, the output commands copy the message into that buffer.  It is
  546. up to you to save the buffer eventually in its file.
  547.  
  548.    You can also output a message to an Rmail file chosen with a menu.
  549. Choose first the menu bar Classify item, then from the Classify menu
  550. choose the Output Rmail Menu item; then choose the Rmail file you want.
  551. This outputs the current message to that file, like the `o' command.
  552. The variables `rmail-secondary-file-directory' and
  553. `rmail-secondary-file-regexp' specify which files to offer in the menu:
  554. the first variable says which directory to find them in; the second
  555. says which files in that directory to offer (all those that match the
  556. regular expression).
  557.  
  558.    Copying a message gives the original copy of the message the `filed'
  559. attribute, so that `filed' appears in the mode line when such a message
  560. is current.  If you like to keep just a single copy of every mail
  561. message, set the variable `rmail-delete-after-output' to `t'; then the
  562. `o' and `C-o' commands delete the original message after copying it.
  563. (You can undelete the original afterward if you wish.)
  564.  
  565.    Copying messages into files in system inbox format uses the header
  566. fields that are displayed in Rmail at the time.  Thus, if you use the
  567. `t' command to view the entire header and then copy the message, the
  568. entire header is copied.  *Note Rmail Display::.
  569.  
  570.    The variable `rmail-output-file-alist' lets you specify intelligent
  571. defaults for the output file, based on the contents of the current
  572. message.  The value should be a list whose elements have this form:
  573.  
  574.      (REGEXP . NAME-EXP)
  575.  
  576. If there's a match for REGEXP in the current message, then the default
  577. file name for output is NAME-EXP.  If multiple elements match the
  578. message, the first matching element decides the default file name.  The
  579. subexpression NAME-EXP may be a string constant giving the file name to
  580. use, or more generally it may be any Lisp expression that returns a
  581. file name as a string.  `rmail-output-file-alist' applies to both `o'
  582. and `C-o'.
  583.  
  584. 
  585. File: emacs,  Node: Rmail Labels,  Next: Rmail Reply,  Prev: Rmail Output,  Up: Rmail
  586.  
  587. Labels
  588. ======
  589.  
  590.    Each message can have various "labels" assigned to it as a means of
  591. classification.  Each label has a name; different names are different
  592. labels.  Any given label is either present or absent on a particular
  593. message.  A few label names have standard meanings and are given to
  594. messages automatically by Rmail when appropriate; these special labels
  595. are called "attributes".  All other labels are assigned only by users.
  596.  
  597. `a LABEL RET'
  598.      Assign the label LABEL to the current message (`rmail-add-label').
  599.  
  600. `k LABEL RET'
  601.      Remove the label LABEL from the current message
  602.      (`rmail-kill-label').
  603.  
  604. `C-M-n LABELS RET'
  605.      Move to the next message that has one of the labels LABELS
  606.      (`rmail-next-labeled-message').
  607.  
  608. `C-M-p LABELS RET'
  609.      Move to the previous message that has one of the labels LABELS
  610.      (`rmail-previous-labeled-message').
  611.  
  612. `C-M-l LABELS RET'
  613.      Make a summary of all messages containing any of the labels LABELS
  614.      (`rmail-summary-by-labels').
  615.  
  616.    The `a' (`rmail-add-label') and `k' (`rmail-kill-label') commands
  617. allow you to assign or remove any label on the current message.  If the
  618. LABEL argument is empty, it means to assign or remove the same label
  619. most recently assigned or removed.
  620.  
  621.    Once you have given messages labels to classify them as you wish,
  622. there are two ways to use the labels: in moving and in summaries.
  623.  
  624.    The command `C-M-n LABELS RET' (`rmail-next-labeled-message') moves
  625. to the next message that has one of the labels LABELS.  The argument
  626. LABELS specifies one or more label names, separated by commas.  `C-M-p'
  627. (`rmail-previous-labeled-message') is similar, but moves backwards to
  628. previous messages.  A numeric argument to either command serves as a
  629. repeat count.
  630.  
  631.    The command `C-M-l LABELS RET' (`rmail-summary-by-labels') displays
  632. a summary containing only the messages that have at least one of a
  633. specified set of messages.  The argument LABELS is one or more label
  634. names, separated by commas.  *Note Rmail Summary::, for information on
  635. summaries.
  636.  
  637.    If the LABELS argument to `C-M-n', `C-M-p' or `C-M-l' is empty, it
  638. means to use the last set of labels specified for any of these commands.
  639.  
  640.    Some labels such as `deleted' and `filed' have built-in meanings and
  641. are assigned to or removed from messages automatically at appropriate
  642. times; these labels are called "attributes".  Here is a list of Rmail
  643. attributes:
  644.  
  645. `unseen'
  646.      Means the message has never been current.  Assigned to messages
  647.      when they come from an inbox file, and removed when a message is
  648.      made current.  When you start Rmail, it initially shows the first
  649.      message that has this attribute.
  650.  
  651. `deleted'
  652.      Means the message is deleted.  Assigned by deletion commands and
  653.      removed by undeletion commands (*note Rmail Deletion::.).
  654.  
  655. `filed'
  656.      Means the message has been copied to some other file.  Assigned by
  657.      the file output commands (*note Rmail Files::.).
  658.  
  659. `answered'
  660.      Means you have mailed an answer to the message.  Assigned by the
  661.      `r' command (`rmail-reply').  *Note Rmail Reply::.
  662.  
  663. `forwarded'
  664.      Means you have forwarded the message.  Assigned by the `f' command
  665.      (`rmail-forward').  *Note Rmail Reply::.
  666.  
  667. `edited'
  668.      Means you have edited the text of the message within Rmail.  *Note
  669.      Rmail Editing::.
  670.  
  671. `resent'
  672.      Means you have resent the message.  Assigned by the command `M-x
  673.      rmail-resend'.  *Note Rmail Reply::.
  674.  
  675.    All other labels are assigned or removed only by the user, and have
  676. no standard meaning.
  677.  
  678. 
  679. File: emacs,  Node: Rmail Reply,  Next: Rmail Summary,  Prev: Rmail Labels,  Up: Rmail
  680.  
  681. Sending Replies
  682. ===============
  683.  
  684.    Rmail has several commands that use Mail mode to send outgoing mail.
  685. *Note Sending Mail::, for information on using Mail mode.  What are
  686. documented here are the special commands of Rmail for entering Mail
  687. mode.  Note that the usual keys for sending mail--`C-x m', `C-x 4 m',
  688. and `C-x 5 m'--are available in Rmail mode and work just as they
  689. usually do.
  690.  
  691. `m'
  692.      Send a message (`rmail-mail').
  693.  
  694. `c'
  695.      Continue editing already started outgoing message
  696.      (`rmail-continue').
  697.  
  698. `r'
  699.      Send a reply to the current Rmail message (`rmail-reply').
  700.  
  701. `f'
  702.      Forward current message to other users (`rmail-forward').
  703.  
  704. `C-u f'
  705.      Resend the current message to other users (`rmail-resend').
  706.  
  707. `M-m'
  708.      Try sending a bounced message a second time
  709.      (`rmail-retry-failure').
  710.  
  711.    The most common reason to send a message while in Rmail is to reply
  712. to the message you are reading.  To do this, type `r' (`rmail-reply').
  713. This displays the `*mail*' buffer in another window, much like `C-x 4
  714. m', but preinitializes the `Subject', `To', `CC' and `In-reply-to'
  715. header fields based on the message you are replying to.  The `To' field
  716. starts out as the address of the person who sent the message you
  717. received, and the `CC' field starts out with all the other recipients
  718. of that message.
  719.  
  720.    You can exclude certain recipients from being placed automatically in
  721. the `CC', using the variable `rmail-dont-reply-to-names'.  Its value
  722. should be a regular expression (as a string); any recipient that the
  723. regular expression matches, is excluded from the `CC' field.  The
  724. default value matches your own name, and any name starting with
  725. `info-'.  (Those names are excluded because there is a convention of
  726. using them for large mailing lists to broadcast announcements.)
  727.  
  728.    To omit the `CC' field completely for a particular reply, enter the
  729. reply command with a numeric argument: `C-u r' or `1 r'.
  730.  
  731.    Once the `*mail*' buffer has been initialized, editing and sending
  732. the mail goes as usual (*note Sending Mail::.).  You can edit the
  733. presupplied header fields if they are not right for you.  You can also
  734. use the commands of Mail mode, including `C-c C-y' to yank in the
  735. message that you are replying to, and `C-c C-q' to fill what was thus
  736. yanked.  You can also switch to the Rmail buffer, select a different
  737. message, switch back, and yank the new current message.
  738.  
  739.    Sometimes a message does not reach its destination.  Mailers usually
  740. send the failed message back to you, enclosed in a "failure message".
  741. The Rmail command `M-m' (`rmail-retry-failure') prepares to send the
  742. same message a second time: it sets up a `*mail*' buffer with the same
  743. text and header fields as before.  If you type `C-c C-c' right away,
  744. you send the message again exactly the same as the first time.
  745. Alternatively, you can edit the text or headers and then send it.
  746.  
  747.    Another frequent reason to send mail in Rmail is to "forward" the
  748. current message to other users.  `f' (`rmail-forward') makes this easy
  749. by preinitializing the `*mail*' buffer with the current message as the
  750. text, and a subject designating a forwarded message.  All you have to
  751. do is fill in the recipients and send.  When you forward a message,
  752. recipients get a message which is "from" you, and which has the
  753. original message in its contents.
  754.  
  755.    "Resending" is an alternative similar to forwarding; the difference
  756. is that resending sends a message that is "from" the original sender,
  757. just as it reached you--with a few added header fields `Resent-from'
  758. and `Resent-to' to indicate that it came via you.  To resend a message
  759. in Rmail, use `C-u f'.  (`f' runs `rmail-forward', which is programmed
  760. to invoke `rmail-resend' if you provide a numeric argument.)
  761.  
  762.    The `m' (`rmail-mail') command is used to start editing an outgoing
  763. message that is not a reply.  It leaves the header fields empty.  Its
  764. only difference from `C-x 4 m' is that it makes the Rmail buffer
  765. accessible for `C-c C-y', just as `r' does.  Thus, `m' can be used to
  766. reply to or forward a message; it can do anything `r' or `f' can do.
  767.  
  768.    The `c' (`rmail-continue') command resumes editing the `*mail*'
  769. buffer, to finish editing an outgoing message you were already
  770. composing, or to alter a message you have sent.
  771.  
  772.    If you set the variable `rmail-mail-new-frame' to a non-`nil' value,
  773. then all the Rmail commands to start sending a message create a new
  774. frame to edit it in.  This frame is deleted when you send the message,
  775. or when you use the `Don't Send' item in the `Mail' menu.
  776.  
  777. 
  778. File: emacs,  Node: Rmail Summary,  Next: Rmail Sorting,  Prev: Rmail Reply,  Up: Rmail
  779.  
  780. Summaries
  781. =========
  782.  
  783.    A "summary" is a buffer containing one line per message to give you
  784. an overview of the mail in an Rmail file.  Each line shows the message
  785. number, the sender, the labels, and the subject.  Almost all Rmail
  786. commands are valid in the summary buffer also; these apply to the
  787. message described by the current line of the summary.  Moving point in
  788. the summary buffer selects messages as you move to their summary lines.
  789.  
  790.    A summary buffer applies to a single Rmail file only; if you are
  791. editing multiple Rmail files, each one can have its own summary buffer.
  792. The summary buffer name is made by appending `-summary' to the Rmail
  793. buffer's name.  Normally only one summary buffer is displayed at a time.
  794.  
  795. * Menu:
  796.  
  797. * Rmail Make Summary::         Making various sorts of summaries.
  798. * Rmail Summary Edit::         Manipulating messages from the summary.
  799.  
  800. 
  801. File: emacs,  Node: Rmail Make Summary,  Next: Rmail Summary Edit,  Up: Rmail Summary
  802.  
  803. Making Summaries
  804. ----------------
  805.  
  806.    Here are the commands to create a summary for the current Rmail file.
  807. Once the Rmail file has a summary buffer, changes in the Rmail file
  808. (such as deleting or expunging messages, and getting new mail)
  809. automatically update the summary.
  810.  
  811. `h'
  812. `C-M-h'
  813.      Summarize all messages (`rmail-summary').
  814.  
  815. `l LABELS RET'
  816. `C-M-l LABELS RET'
  817.      Summarize message that have one or more of the specified labels
  818.      (`rmail-summary-by-labels').
  819.  
  820. `C-M-r RCPTS RET'
  821.      Summarize messages that have one or more of the specified
  822.      recipients (`rmail-summary-by-recipients').
  823.  
  824. `C-M-t TOPIC RET'
  825.      Summarize messages that have a match for the specified regexp
  826.      TOPIC in their subjects (`rmail-summary-by-topic').
  827.  
  828.    The `h' or `C-M-h' (`rmail-summary') command fills the summary buffer
  829. for the current Rmail file with a summary of all the messages in the
  830. file.  It then displays and selects the summary buffer in another
  831. window.
  832.  
  833.    `C-M-l LABELS RET' (`rmail-summary-by-labels') makes a partial
  834. summary mentioning only the messages that have one or more of the
  835. labels LABELS.  LABELS should contain label names separated by commas.
  836.  
  837.    `C-M-r RCPTS RET' (`rmail-summary-by-recipients') makes a partial
  838. summary mentioning only the messages that have one or more of the
  839. recipients RCPTS.  RCPTS should contain mailing addresses separated by
  840. commas.
  841.  
  842.    `C-M-t TOPIC RET' (`rmail-summary-by-topic') makes a partial summary
  843. mentioning only the messages whose subjects have a match for the
  844. regular expression TOPIC.
  845.  
  846.    Note that there is only one summary buffer for any Rmail file;
  847. making one kind of summary discards any previously made summary.
  848.  
  849.    The variable `rmail-summary-window-size' says how many lines to use
  850. for the summary window.
  851.  
  852. 
  853. File: emacs,  Node: Rmail Summary Edit,  Prev: Rmail Make Summary,  Up: Rmail Summary
  854.  
  855. Editing in Summaries
  856. --------------------
  857.  
  858.    You can use the Rmail summary buffer to do almost anything you can do
  859. in the Rmail buffer itself.  In fact, once you have a summary buffer,
  860. there's no need to switch back to the Rmail buffer.
  861.  
  862.    You can select and display various messages in the Rmail buffer, from
  863. the summary buffer, just by moving point in the summary buffer to
  864. different lines.  It doesn't matter what Emacs command you use to move
  865. point; whichever line point is on at the end of the command, that
  866. message is selected in the Rmail buffer.
  867.  
  868.    Almost all Rmail commands work in the summary buffer as well as in
  869. the Rmail buffer.  Thus, `d' in the summary buffer deletes the current
  870. message, `u' undeletes, and `x' expunges.  `o' and `C-o' output the
  871. current message to a file; `r' starts a reply to it.  You can scroll
  872. the current message while remaining in the summary buffer using SPC and
  873. DEL.
  874.  
  875.    The Rmail commands to move between messages also work in the summary
  876. buffer, but with a twist: they move through the set of messages included
  877. in the summary.  They also ensure the Rmail buffer appears on the screen
  878. (unlike cursor motion commands, which update the contents of the Rmail
  879. buffer but don't display it in a window unless it already appears).
  880. Here is a list of these commands:
  881.  
  882. `n'
  883.      Move to next line, skipping lines saying `deleted', and select its
  884.      message.
  885.  
  886. `p'
  887.      Move to previous line, skipping lines saying `deleted', and select
  888.      its message.
  889.  
  890. `M-n'
  891.      Move to next line and select its message.
  892.  
  893. `M-p'
  894.      Move to previous line and select its message.
  895.  
  896. `>'
  897.      Move to the last line, and select its message.
  898.  
  899. `<'
  900.      Move to the first line, and select its message.
  901.  
  902. `M-s PATTERN RET'
  903.      Search through messages for PATTERN starting with the current
  904.      message; select the message found, and move point in the summary
  905.      buffer to that message's line.
  906.  
  907.    Deletion, undeletion, and getting new mail, and even selection of a
  908. different message all update the summary buffer when you do them in the
  909. Rmail buffer.  If the variable `rmail-redisplay-summary' is non-`nil',
  910. these actions also bring the summary buffer back onto the screen.
  911.  
  912.    When you are finished using the summary, type `w'
  913. (`rmail-summary-wipe') to kill the summary buffer's window.  You can
  914. also exit Rmail while in the summary.  `q' (`rmail-summary-quit') kills
  915. the summary window, then saves the Rmail file and switches to another
  916. buffer.
  917.  
  918. 
  919. File: emacs,  Node: Rmail Sorting,  Next: Rmail Display,  Prev: Rmail Summary,  Up: Rmail
  920.  
  921. Sorting the Rmail File
  922. ======================
  923.  
  924. `M-x rmail-sort-by-date'
  925.      Sort messages of current Rmail file by date.
  926.  
  927. `M-x rmail-sort-by-subject'
  928.      Sort messages of current Rmail file by subject.
  929.  
  930. `M-x rmail-sort-by-author'
  931.      Sort messages of current Rmail file by author's name.
  932.  
  933. `M-x rmail-sort-by-recipient'
  934.      Sort messages of current Rmail file by recipient's names.
  935.  
  936. `M-x rmail-sort-by-correspondent'
  937.      Sort messages of current Rmail file by the name of the other
  938.      correspondent.
  939.  
  940. `M-x rmail-sort-by-lines'
  941.      Sort messages of current Rmail file by size (number of lines).
  942.  
  943. `M-x rmail-sort-by-keywords RET LABELS RET'
  944.      Sort messages of current Rmail file by labels.  The argument
  945.      LABELS should be a comma-separated list of labels.  The order of
  946.      these labels specifies the order of messages; messages with the
  947.      first label come first, messages with the second label come
  948.      second, and so on.  Messages which have none of these labels come
  949.      last.
  950.  
  951.    The Rmail sort commands perform a *stable sort*: if there is no
  952. reason to prefer either one of two messages, their order remains
  953. unchanged.  You can use this to sort by more than one criterion.  For
  954. example, if you use `rmail-sort-by-date' and then
  955. `rmail-sort-by-author', messages from the same author appear in order
  956. by date.
  957.  
  958.    With a numeric argument, all these commands reverse the order of
  959. comparison.  This means they sort messages from newest to oldest, from
  960. biggest to smallest, or in reverse alphabetical order.
  961.  
  962. 
  963. File: emacs,  Node: Rmail Display,  Next: Rmail Editing,  Prev: Rmail Sorting,  Up: Rmail
  964.  
  965. Display of Messages
  966. ===================
  967.  
  968.    Rmail reformats the header of each message before displaying it for
  969. the first time.  Reformatting hides uninteresting header fields to
  970. reduce clutter.  You can use the `t' command to show the entire header
  971. or to repeat the header reformatting operation.
  972.  
  973. `t'
  974.      Toggle display of complete header (`rmail-toggle-headers').
  975.  
  976.    Reformatting the header involves deleting most header fields, on the
  977. grounds that they are not interesting.  The variable
  978. `rmail-ignored-headers' holds a regular expression that specifies which
  979. header fields to hide in this way--if it matches the beginning of a
  980. header field, that whole field is hidden.
  981.  
  982.    Rmail saves the complete original header before reformatting; to see
  983. it, use the `t' command (`rmail-toggle-headers').  This discards the
  984. reformatted headers of the current message and displays it with the
  985. original header.  Repeating `t' reformats the message again.  Selecting
  986. the message again also reformats.
  987.  
  988.    When used with a window system that supports multiple fonts, Rmail
  989. highlights certain header fields that are especially interesting--by
  990. default, the `From' and `Subject' fields.  The variable
  991. `rmail-highlighted-headers' holds a regular expression that specifies
  992. the header fields to highlight; if it matches the beginning of a header
  993. field, that whole field is highlighted.
  994.  
  995.    If you specify unusual colors for your text foreground and
  996. background, the colors used for highlighting may not go well with them.
  997. If so, specify different colors for the `highlight' face.  That is
  998. worth doing because the `highlight' face is used for other kinds of
  999. highlighting as well.  *Note Faces::, for how to do this.
  1000.  
  1001.    To turn off highlighting entirely in Rmail, set
  1002. `rmail-highlighted-headers' to `nil'.
  1003.  
  1004. 
  1005. File: emacs,  Node: Rmail Editing,  Next: Rmail Digest,  Prev: Rmail Display,  Up: Rmail
  1006.  
  1007. Editing Within a Message
  1008. ========================
  1009.  
  1010.    Most of the usual Emacs commands are available in Rmail mode, though
  1011. a few, such as `C-M-n' and `C-M-h', are redefined by Rmail for other
  1012. purposes.  However, the Rmail buffer is normally read only, and most of
  1013. the letters are redefined as Rmail commands.  If you want to edit the
  1014. text of a message, you must use the Rmail command `e'.
  1015.  
  1016. `e'
  1017.      Edit the current message as ordinary text.
  1018.  
  1019.    The `e' command (`rmail-edit-current-message') switches from Rmail
  1020. mode into Rmail Edit mode, another major mode which is nearly the same
  1021. as Text mode.  The mode line indicates this change.
  1022.  
  1023.    In Rmail Edit mode, letters insert themselves as usual and the Rmail
  1024. commands are not available.  When you are finished editing the message
  1025. and are ready to go back to Rmail, type `C-c C-c', which switches back
  1026. to Rmail mode.  Alternatively, you can return to Rmail mode but cancel
  1027. all the editing that you have done, by typing `C-c C-]'.
  1028.  
  1029.    Entering Rmail Edit mode runs the hook `text-mode-hook'; then it
  1030. runs the hook `rmail-edit-mode-hook' (*note Hooks::.).  It adds the
  1031. attribute `edited' to the message.
  1032.  
  1033. 
  1034. File: emacs,  Node: Rmail Digest,  Next: Out of Rmail,  Prev: Rmail Editing,  Up: Rmail
  1035.  
  1036. Digest Messages
  1037. ===============
  1038.  
  1039.    A "digest message" is a message which exists to contain and carry
  1040. several other messages.  Digests are used on some moderated mailing
  1041. lists; all the messages that arrive for the list during a period of time
  1042. such as one day are put inside a single digest which is then sent to the
  1043. subscribers.  Transmitting the single digest uses much less computer
  1044. time than transmitting the individual messages even though the total
  1045. size is the same, because the per-message overhead in network mail
  1046. transmission is considerable.
  1047.  
  1048.    When you receive a digest message, the most convenient way to read
  1049. it is to "undigestify" it: to turn it back into many individual
  1050. messages.  Then you can read and delete the individual messages as it
  1051. suits you.
  1052.  
  1053.    To do this, select the digest message and type the command `M-x
  1054. undigestify-rmail-message'.  This extracts the submessages as separate
  1055. Rmail messages, and inserts them following the digest.  The digest
  1056. message itself is flagged as deleted.
  1057.  
  1058. 
  1059. File: emacs,  Node: Out of Rmail,  Next: Rmail Rot13,  Prev: Rmail Digest,  Up: Rmail
  1060.  
  1061. Converting an Rmail File to Inbox Format
  1062. ========================================
  1063.  
  1064.    The command `M-x unrmail' converts a file in Rmail format to inbox
  1065. format (also known as the system mailbox format), so that you can use it
  1066. with other mail-editing tools.  You must specify two arguments, the name
  1067. of the Rmail file and the name to use for the converted file.  `M-x
  1068. unrmail' does not alter the Rmail file itself.
  1069.  
  1070. 
  1071. File: emacs,  Node: Rmail Rot13,  Prev: Out of Rmail,  Up: Rmail
  1072.  
  1073. Reading Rot13 Messages
  1074. ======================
  1075.  
  1076.    Mailing list messages that might offend some readers are sometimes
  1077. encoded in a simple code called "rot13"--so named because it rotates
  1078. the alphabet by 13 letters.  This code is not for secrecy, as it
  1079. provides none; rather, it enables those who might be offended to avoid
  1080. ever seeing the real text of the message.
  1081.  
  1082.    To view a buffer using the rot13 code, use the command `M-x
  1083. rot13-other-window'.  This displays the current buffer in another window
  1084. which applies the code when displaying the text.
  1085.  
  1086. 
  1087. File: emacs,  Node: Dired,  Next: Calendar/Diary,  Prev: Rmail,  Up: Top
  1088.  
  1089. Dired, the Directory Editor
  1090. ***************************
  1091.  
  1092.    Dired makes an Emacs buffer containing a listing of a directory, and
  1093. optionally some of its subdirectories as well.  You can use the normal
  1094. Emacs commands to move around in this buffer, and special Dired commands
  1095. to operate on the files listed.
  1096.  
  1097. * Menu:
  1098.  
  1099. * Enter: Dired Enter.         How to invoke Dired.
  1100. * Commands: Dired Commands.   Commands in the Dired buffer.
  1101. * Deletion: Dired Deletion.   Deleting files with Dired.
  1102. * Flagging Many Files::       Flagging files based on their names.
  1103. * Visit: Dired Visiting.      Other file operations through Dired.
  1104. * Marks vs Flags::          Flagging for deletion vs marking.
  1105. * Operating on Files::          How to copy, rename, print, compress, etc.
  1106.                     either one file or several files.
  1107. * Shell Commands in Dired::   Running a shell command on the marked files.
  1108. * Transforming File Names::   Using patterns to rename multiple files.
  1109. * Comparison in Dired::          Running `diff' by way of Dired.
  1110. * Subdirectories in Dired::   Adding subdirectories to the Dired buffer.
  1111. * Subdirectory Motion::          Moving across subdirectories, and up and down.
  1112. * Hiding Subdirectories::     Making subdirectories visible or invisible.
  1113. * Updating: Dired Updating.   Discarding lines for files of no interest.
  1114. * Find: Dired and Find.          Using `find' to choose the files for Dired.
  1115.  
  1116. 
  1117. File: emacs,  Node: Dired Enter,  Next: Dired Commands,  Up: Dired
  1118.  
  1119. Entering Dired
  1120. ==============
  1121.  
  1122.    To invoke Dired, do `C-x d' or `M-x dired'.  The command reads a
  1123. directory name or wildcard file name pattern as a minibuffer argument
  1124. to specify which files to list.  Where `dired' differs from
  1125. `list-directory' is in putting the buffer into Dired mode so that the
  1126. special commands of Dired are available.
  1127.  
  1128.    The variable `dired-listing-switches' specifies the options to give
  1129. to `ls' for listing directory; this string *must* contain `-l'.  If you
  1130. use a numeric prefix argument with the `dired' command, you can specify
  1131. the `ls' switches with the minibuffer after you finish entering the
  1132. directory specification.
  1133.  
  1134.    To display the Dired buffer in another window rather than in the
  1135. selected window, use `C-x 4 d' (`dired-other-window)' instead of `C-x
  1136. d'.  `C-x 5 d' (`dired-other-frame') uses a separate frame to display
  1137. the Dired buffer.
  1138.  
  1139. 
  1140. File: emacs,  Node: Dired Commands,  Next: Dired Deletion,  Prev: Dired Enter,  Up: Dired
  1141.  
  1142. Commands in the Dired Buffer
  1143. ============================
  1144.  
  1145.    The Dired buffer is "read-only", and inserting text in it is not
  1146. useful, so ordinary printing characters such as `d' and `x' are used
  1147. for special Dired commands.  Some Dired commands "mark" or "flag" the
  1148. "current file" (that is, the file on the current line); other commands
  1149. operate on the marked files or on the flagged files.
  1150.  
  1151.    All the usual Emacs cursor motion commands are available in Dired
  1152. buffers.  Some special purpose cursor motion commands are also
  1153. provided.  The keys `C-n' and `C-p' are redefined to put the cursor at
  1154. the beginning of the file name on the line, rather than at the
  1155. beginning of the line.
  1156.  
  1157.    For extra convenience, SPC and `n' in Dired are equivalent to `C-n'.
  1158. `p' is equivalent to `C-p'.  (Moving by lines is so common in Dired
  1159. that it deserves to be easy to type.)  DEL (move up and unflag) is
  1160. often useful simply for moving up.
  1161.  
  1162.